package com.flyox.game.militarychess.bean;

import java.io.Serializable;


public class ChessSeat implements Serializable {

	private static final long serialVersionUID = 8988013399894015345L;
	/**
	 * S1 S2 S3 S4
	 * S5 S6 S7 S8
	 */
	public static enum SEAT_NAME {S1, S2, S3, S4, S5, S6, S7, S8};
	public static enum SEAT_STATE{EMPTY,ONSEAT,OFFLINE};
	
	private SEAT_STATE seatState=SEAT_STATE.EMPTY;
	private String playerID;
	private SEAT_NAME seatName;
	
	public ChessSeat(SEAT_NAME seatName){
		this.seatName=seatName;
	}
	public SEAT_STATE getSeatState() {
		return seatState;
	}
	public void setSeatState(SEAT_STATE seatState) {
		this.seatState = seatState;
	}
	public String getPlayerID() {
		return playerID;
	}
	public void setPlayerID(String playerID) {
		this.playerID = playerID;
	}
	public String toString(){
		return "seatState="+seatState.name()+" playerID="+playerID;
	}
	public SEAT_NAME getSeatName() {
		return seatName;
	}
	public void setSeatName(SEAT_NAME seatName) {
		this.seatName = seatName;
	}
	
//	public static Color getSeatColor(SEAT_NAME seatName) {
//		switch(seatName){
//		case S1:
//			return new Color(0x2E,0x69,0xA6);
//		case S2:
//			return new Color(0x31,0x8A,0x9B);
//		case S3:
//			return new Color(0x74,0x9D,0x04);
//		case S4:
//			return new Color(0x17,0x80,0x53);
//		case S5:
//			return new Color(0xDC,0x6D,0x00);
//		case S6:
//			return new Color(0xA0,0x4F,0x02);
//		case S7:
//			return new Color(0x90,0x44,0xA6);
//		case S8:
//			return new Color(0x63,0x35,0x53);
//		default:
//			return new Color(255,255,255);
//		}
//	}
//	
//	public Color getSeatColor() {
//		switch(seatName){
//		case S1:
//			return new Color(0x2E,0x69,0xA6);
//		case S2:
//			return new Color(0x31,0x8A,0x9B);
//		case S3:
//			return new Color(0x74,0x9D,0x04);
//		case S4:
//			return new Color(0x17,0x80,0x53);
//		case S5:
//			return new Color(0xDC,0x6D,0x00);
//		case S6:
//			return new Color(0xA0,0x4F,0x02);
//		case S7:
//			return new Color(0x90,0x44,0xA6);
//		case S8:
//			return new Color(0x63,0x35,0x53);
//		default:
//			return new Color(255,255,255);
//		}
//	}
}
